package model.kwalificatiebeheer;

import java.util.ArrayList;

import model.kwalificatiebeheer.Competentie;

public class CompetentieBestand {
	/**
	 * Variables
	 */
	private static final CompetentieBestand cb = new CompetentieBestand();
	private ArrayList<Competentie> competenties = new ArrayList<Competentie>();
	
	/**
	 * Constructors
	 */
	private CompetentieBestand() {
		competenties.add(new Competentie("A","Beslissen en activiteiten"));
		competenties.add(new Competentie("B","Aansturen"));
		competenties.add(new Competentie("C","Begeleiden"));
		competenties.add(new Competentie("E","Aandacht en begrip tonen"));
		competenties.add(new Competentie("F","Samenwerken en overleggen"));
		competenties.add(new Competentie("G","Ethisch en integer handelen"));
		competenties.add(new Competentie("H","Relaties bouwen en netwerken"));
		competenties.add(new Competentie("I","Presenteren"));
		competenties.add(new Competentie("J","Formuleren en rapporteren"));
		competenties.add(new Competentie("K","Vakdeskundigheid"));
		competenties.add(new Competentie("L","Materialen en middelen inzetten"));
		competenties.add(new Competentie("M","Analyseren"));
		competenties.add(new Competentie("N","Onderzoeken"));
		competenties.add(new Competentie("O","Cre�ren en innoveren"));
		competenties.add(new Competentie("P","Leren"));
		competenties.add(new Competentie("Q","Plannen en organiseren"));
		competenties.add(new Competentie("R","Op de behoeften en verwachtingen van de 'klant' richten"));
		competenties.add(new Competentie("S","Kwaliteit leveren"));
		competenties.add(new Competentie("T","Instructies en procedures opvolgen"));
		competenties.add(new Competentie("U","Omgaan met verandering en aanpassen"));
		competenties.add(new Competentie("V","Met druk en Tegenslag omgaan"));
		competenties.add(new Competentie("W","Gedrevenheid en ambitie"));
		competenties.add(new Competentie("X","Ondernemend en commercieel handelen"));
		competenties.add(new Competentie("Y","Bedrijfsmatig handelen"));
	}
	
	public static CompetentieBestand getInstance(){
		return cb;
	}
	
	/**
	 * Getters and Setters
	 */
	public ArrayList<Competentie> getCompetenties() {
		return competenties;
	}

	public void setCompetenties(ArrayList<Competentie> competenties) {
		this.competenties = competenties;
	}
	
	public void addCompetentie(Competentie comp){
		competenties.add(comp);
	}
	
	/**
	 * @name:	 	getCompetentie
	 * @param:		Competentie comp		
	 * @description:Returns competentie from list if match, else 
	 * 				return received competentie.
	 * @return:		Competentie
	 */
	public Competentie getCompetentie(Competentie comp){
		for(Competentie tempComp: competenties){
			if(comp.equals(tempComp)){
				return tempComp;
			}
		}
		return comp;
	}
	
	/**
	 * @name:	 	deleteCompetentie
	 * @param:		Competentie comp1		
	 * @description:deletes competentie
	 * @return:		void
	 */
	public void deleteCompetentie(Competentie comp1){
		competenties.remove(comp1);
		
		
	}
	
}
